Skip to main content

QA your Analysis: Tips & Best Practices

This page covers some best practices to verify your work within Fused.

Creating Visualizations in Canvas

Fused Canvas allows you to create dependencies between UDFs. You can leverage this to your benefit by creating a simple chain of UDFs that visualizes a dataset for you

  • Each time you rerun AND save the UDF, the downstream map will be re-rendered (be sure to set cache_max_age=0 in the downstream UDF to avoid caching the result)
Example: Visualizing a dataset in Canvas

Data UDF (here called copdem_elevation_hex6):

@fused.udf
def udf(
bounds: fused.types.Bounds = [-74.556, 40.400, -73.374, 41.029], # Default to full NYC
res: int = 6,
):
path = "s3://fused-asset/hex/copernicus-dem-90m/"

hex_reader = fused.load("https://github.com/fusedio/udfs/tree/8024b5c/community/joris/Read_H3_dataset/")
df = hex_reader.read_h3_dataset(path, bounds, res=res)

return df

Map UDF:

@fused.udf(cache_max_age=0) # Be sure to set cache_max_age to 0 to avoid caching the result
def udf(
bounds: fused.types.Bounds = [-74.556, 40.4, -73.374, 41.029],
res: int = 6,
):
map_utils = fused.load(
"https://github.com/fusedio/udfs/tree/6fc554d/community/milind/map_utils/"
)
df = fused.run("copdem_elevation_hex6", bounds=bounds, res=res)

config = {
"hexLayer": {
"@@type": "H3HexagonLayer",
"stroked": True,
"filled": True,
"pickable": True,
"getLineColor": [100, 100, 100, 200],
"getLineWidth": 2,
"getFillColor": {
"@@function": "colorContinuous",
"attr": "data_avg",
"domain": [0, 100],
"colors": "Earth"
},
"tooltipColumns": ["data_avg"]
}
}

return map_utils.deckgl_hex(df, config=config, layers=[{"type": "hex", "data": df, "config": config, "name": "Elevation"}])

Helpful when:

  • You want to always have an up-to-date visualization of your data directly in Canvas
  • You want to share a visualization with someone else without having to export it to a file (every UDF is standalone in Canvas)

Related docs:

Compare Results in UDF Builder view

The UDF Builder view allows you to visualize multiple layers of data at once. This is a great way to QA your data.

Helpful when:

  • Working with different geospatial data sources covering the same area. For example:
    • Comparing the original raster dataset to the ingested H3 version
    • Working with different time periods of the same dataset (e.g. comparing 2024 vs 2025)
  • You want to get a quick look at the data at scale by leveraging the Tile mode
  • You don't need a shareable visualization but simply want to visually inspect your data as part of your QA process

Related docs:

More Tips & Best Practices